package com.mystudy.leetcode.problem.other.p_1108;

import org.junit.Test;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

/**
 * @program: infoalgorithm
 * @description: IP地址无效化
 * @author: zhouzhilong
 * @create: 2019-07-10 17:25
 **/
public class Solution {
    /** logger */
    private static final Logger LOGGER = LoggerFactory.getLogger(Solution.class);

    @Test
    public void test(){
        String s = defangIPaddr("192.168.200.236");
        LOGGER.debug("s:{}",s);
    }

    /**
     * 取巧了，应该不是考察这个
     * @param address
     * @return
     */
    public String defangIPaddr(String address) {
        return address.replace(".","[.]");
    }
}
